﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Avatar.Model;
using AvatarHelper;

namespace Avatar.MembershipService
{
    public class AccessRoleManager
    {
        public static bool AddRole(int _groupID,string _fileName,bool _access)
        {
            AccessRole _role = new AccessRole();
            _role.GroupID = _groupID;
            _role.FileName = _fileName;
            _role.Access = _access;

            return DBHelper.Insert(_role, r => r.GroupID == _groupID && r.FileName == _fileName, "添加访问规则出错:");
        }
    }
}
